package com.laowang.project.system.service.impl;

import java.util.Date;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.laowang.project.system.mapper.MyCyhPartnerVipNumMapper;
import com.laowang.project.system.domain.MyCyhPartnerVipNum;
import com.laowang.project.system.service.MyCyhPartnerVipNumService;

/**
 * 合伙人分享会员明细Service业务层处理
 *
 * @author laowang
 * @date 2024-01-25
 */
@Service
public class MyCyhPartnerVipNumServiceImpl implements MyCyhPartnerVipNumService {
    @Autowired
    private MyCyhPartnerVipNumMapper myCyhPartnerVipNumMapper;

    /**
     * 查询合伙人分享会员明细
     *
     * @param id 合伙人分享会员明细ID
     * @return 合伙人分享会员明细
     */
    @Override
    public MyCyhPartnerVipNum selectMyCyhPartnerVipNumById(Integer id) {
        return myCyhPartnerVipNumMapper.selectMyCyhPartnerVipNumById(id);
    }

    /**
     * 查询合伙人分享会员明细列表
     *
     * @param myCyhPartnerVipNum 合伙人分享会员明细
     * @return 合伙人分享会员明细
     */
    @Override
    public List<MyCyhPartnerVipNum> selectMyCyhPartnerVipNumList(MyCyhPartnerVipNum myCyhPartnerVipNum) {
        return myCyhPartnerVipNumMapper.selectMyCyhPartnerVipNumList(myCyhPartnerVipNum);
    }

    /**
     * 新增合伙人分享会员明细
     *
     * @param myCyhPartnerVipNum 合伙人分享会员明细
     * @return 结果
     */
    @Override
    public int insertMyCyhPartnerVipNum(MyCyhPartnerVipNum myCyhPartnerVipNum) {
        myCyhPartnerVipNum.setCreated(new Date());
        return myCyhPartnerVipNumMapper.insertMyCyhPartnerVipNum(myCyhPartnerVipNum);
    }

    /**
     * 修改合伙人分享会员明细
     *
     * @param myCyhPartnerVipNum 合伙人分享会员明细
     * @return 结果
     */
    @Override
    public int updateMyCyhPartnerVipNum(MyCyhPartnerVipNum myCyhPartnerVipNum) {
        return myCyhPartnerVipNumMapper.updateMyCyhPartnerVipNum(myCyhPartnerVipNum);
    }

    /**
     * 批量删除合伙人分享会员明细
     *
     * @param ids 需要删除的合伙人分享会员明细ID
     * @return 结果
     */
    @Override
    public int deleteMyCyhPartnerVipNumByIds(Integer[] ids) {
        return myCyhPartnerVipNumMapper.deleteMyCyhPartnerVipNumByIds(ids);
    }

    /**
     * 删除合伙人分享会员明细信息
     *
     * @param id 合伙人分享会员明细ID
     * @return 结果
     */
    @Override
    public int deleteMyCyhPartnerVipNumById(Integer id) {
        return myCyhPartnerVipNumMapper.deleteMyCyhPartnerVipNumById(id);
    }

    @Override
    public Integer selectMyCyhPartnerVipNumListOrder(MyCyhPartnerVipNum myCyhPartnerVipNum) {
        return myCyhPartnerVipNumMapper.selectMyCyhPartnerVipNumListOrder(myCyhPartnerVipNum);
    }

    @Override
    public Integer selectNumber(Integer mid) {
        return myCyhPartnerVipNumMapper.selectNumber(mid);
    }

    @Override
    public List selectMyCyhPartnerVipNumListDetail(MyCyhPartnerVipNum myCyhPartnerVipNum) {
        return myCyhPartnerVipNumMapper.selectMyCyhPartnerVipNumListDetail(myCyhPartnerVipNum);
    }


}
